package de.ars.client.datahandling;

import java.util.Vector;

public class InformationItem
{
	public static final String TYP_TEXT = "TEXT"; 
	public static final String TYP_DIGIT = "DIGIT";
	public static final String TYP_DATE = "DATE";
	public static final String TYP_CHOOSE = "CHOOSE";
	public static final String TYP_STARS = "STARS";
	public static final String TYP_OPTION = "OPTION";
	
    private String key;
    private String typ;
    private Vector options;
    
    public InformationItem(String _name,String _typ)
    {
        this.key = _name;
        this.typ = _typ;
        this.options = new Vector();
    }
    
    public String GetKey()
    {
        return this.key;
    }
    
    public String GetTyp()
    {
    	return this.typ;
    }
    
    public Vector getOptions()
    {
    	Vector result = new Vector();
    	for (int i = 0 ; i < this.options.size();i++)
    		result.addElement(key + "." + this.options.elementAt(i));
    	return result;
    }
    
    public void AddOption(String option)
    {
        this.options.addElement( option );
    }
}
